<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org"
      xmlns:sec="http://www.pollix.at/thymeleaf/shiro" xmlns:class="http://www.w3.org/1999/xhtml">
<head th:replace="admin/common/html/head :: head_Normal(~{::title},~{::link},~{::style})">

    <title th:text=${title}></title>
    <!-- 这儿引用单独的css link -->
    <!-- Ladda for Bootstrap 3按钮加载进度插件 -->
    <link rel="stylesheet" th:href="@{/static/admin/assets/js/button/ladda/ladda.min.css}">
    <!-- bootstrap-table表单样式 -->
    <link th:href="@{/static/admin/assets/js/bootstrap/css/bootstrap-table/bootstrap-table.min.css}" rel="stylesheet"/>
    <!-- select2样式 -->
    <link th:href="@{/static/admin/assets/js/select2/css/select2.min.css}" rel="stylesheet"/>
    <style type="text/css">
        .control-label {
            margin-top: 10px;
        }

        .row{
            margin: 0%;
        }
    </style>

</head>

<body id="listbody">

<!-- 右边内容 -->
<div class="wrap-fluid">
    <div class="container-fluid paper-wrap bevel tlbr">
        <!-- 内容 -->
        <!--标题 通用-->
        <div th:replace="admin/common/html/title :: title(${title},${parenttitle},${isMsg},${msgHTML})">
        </div>
        <!-- 结束标题 通用-->
        <div class="content-wrap">
            <!-- 结束内容 -->
            <div class="row">
                <div class="col-sm-12">
                    <!-- 搜索条件 -->

                    <div class="nest" id="inlineClose">
                        <div class="title-alt">
                            <h6>搜索条件</h6>
                            <div class="titleClose">
                                <a class="gone" href="#inlineClose">
                                    <span class="entypo-cancel"></span>
                                </a>
                            </div>
                            <div class="titleToggle">
                                <a class="nav-toggle-alt" href="#search_div">
                                    <span class="entypo-down-open"></span>
                                </a>
                            </div>
                        </div>

                        <div class="body-flow" id="search_div" style="display: block">
                            <div class="form_left">
                            <form role="form" class="form-group-md" id="form-search">
                                    <div class="row">
                                        <div class="col-md-4 col-sm-3">
                                            <div class="form-group">
                                                <label class="col-sm-4 control-label ">年级：</label>
                                                <div class="col-sm-8">
                                                    <select class="form-control" id="grade-select" name="grade">
                                                        <option value="2017">2017</option>
                                                    </select>
                                                </div>
                                            </div>
                                        </div>
                                        <div class="col-md-4 col-sm-3">
                                            <div class="form-group">
                                                <label class="col-sm-4 control-label ">考试科目：</label>
                                                <div class="col-sm-8">
                                                    <select class="form-control selectpicker" id="course-select" name="courseName"  >
                                                        <option th:each="list : ${courseList}"
                                                                th:text="${list.courseName}"
                                                                th:value="${list.courseName}">
                                                        </option>
                                                    </select>
                                                </div>
                                            </div>
                                        </div>
                                    </div>

                                    <div class="row" >
                                        <div class="col-md-4 col-sm-3">
                                            <div class="form-group">
                                                <label class="col-sm-4 control-label">学院：</label>
                                                <div class="col-sm-8">
                                                    <select class="form-control" id="college_select" name="cid">
                                                        <option value="0">全部学院</option>
                                                        <option th:each="list : ${collegeList}"
                                                                th:text="${list.collegeName}"
                                                                th:value="${list.collegeId}">
                                                        </option>
                                                    </select>
                                                </div>
                                            </div>
                                        </div>
                                        <div class="col-md-4 col-sm-3">
                                            <div class="form-group">
                                                <label class="col-sm-4 control-label ">排序：</label>
                                                <div class="col-sm-8">
                                                    <select class="form-control" id="scoreOder" name="order">
                                                        <option value="ID">默认</option>
                                                        <option value="ASC">总评成绩：低—>高</option>
                                                        <option value="DESC">总评成绩：高—>低</option>
                                                    </select>
                                                </div>
                                            </div>
                                        </div>
                                        <div class="col-md-4 col-sm-3">
                                            <button  onclick="$.table.search(this)" class="btn btn-success"
                                                     type="button"><i class="fa fa-search"></i>&nbsp;搜索
                                            </button>
                                        </div>
                                    </div>

                                </form>
                            </div><br>
                            <div class="row">
                                <div class="col-md-12">
                                    <p>
                                        <strong class="control-label">注：</strong>
                                        1.学院的<u>平时成绩</u>，<u>期末成绩</u>以及<u>总评成绩</u>是学院内所有学生对某一科目的<strong>平均成绩</strong>。<br>
                                        &nbsp;&emsp;&emsp;2.学院成绩分级是以<strong>总评成绩</strong>为标准：<span class="small">优秀：90~100，良好：80~90，中等：70~80，及格：60~70，不及格：低于60</span>
                                    </p>

                                </div>
                            </div>


                        </div>
                    </div>
                    <!-- END搜索条件 -->
                    <!-- 空白页开始-->
                    <div class="nest" id="Blank_PageClose">
                        <div class="title-alt">
                            <h6>学院成绩分析概况表</h6>
                            <div class="titleClose">
                                <a class="gone" href="#Blank_PageClose">
                                    <span class="entypo-cancel"></span>
                                </a>
                            </div>
                            <div class="titleToggle">
                                <a class="nav-toggle-alt" href="#Blank_Page_Content">
                                    <span class="entypo-up-open"></span>
                                </a>
                            </div>
                        </div>

                        <div class="body-nest" id="Blank_Page_Content">
                            <!-- 工具条 -->
                            <div class="btn-group hidden-xs" id="exampleTableEventsToolbar" role="group">


                            </div>
                            <!-- 工具条 end-->
                            <table id="dataTable" class="table-striped footable-res footable metro-blue"
                                   data-page-size="6">

                            </table>
                        </div>
                    </div>
                </div>
                <!-- 空白页结束 -->
            </div>
            <!-- 结束内容 -->
        </div>
    </div>
</div>
<!-- 结束右边内容 -->
<!-- # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # 代码编写处 END# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # -->

<!-- 通用js -->
<div th:include="admin/common/html/js :: onload_js">

</div>
<!-- bootstarp 表格 -->
<script th:src="@{/static/admin/assets/js/bootstrap/js/bootstrap-table/bootstrap-table.min.js}"
        type="text/javascript"></script>
<script th:src="@{/static/admin/assets/js/bootstrap/js/bootstrap-table/locale/bootstrap-table-zh-CN.min.js}"
        type="text/javascript"></script>
<script th:src="@{/static/admin/assets/js/bootstrap/js/base_list.js}" type="text/javascript"></script>
<!-- jquery-export 表格导出插件 -->
<script th:src="@{/static/admin/assets/js/bootstrap/extensions/export/bootstrap-table-export.js}"
        type="text/javascript"></script>
<script th:src="@{/static/admin/assets/js/bootstrap/extensions/export/tableExport.js}" type="text/javascript"></script>

<!-- 弹窗 -->
<script th:src="@{/static/admin/assets/js/layer/layer.js}" type="text/javascript"></script>
<!-- 遮罩层 -->
<script th:src="@{/static/admin/assets/js/blockUI/jquery.blockUI.js}" type="text/javascript"></script>
<script th:src="@{/static/admin/assets/js/select2/js/select2.full.min.js}" type="text/javascript"></script>
<script type="text/javascript">


    //
    <!-- 导出 -->
    var dataUrl = window.rootPath + "/admin/saCollege/list";
    var removeUrl = window.rootPath + "/admin/saCollege/remove";
    var createUrl = window.rootPath + "/admin/saCollege/add";
    var updateUrl = window.rootPath + "/admin/saCollege/edit/{id}";
    var exportUrl = window.rootPath + "/admin/saCollege/export";
    var options = {
        dataUrl: dataUrl,
        createUrl: createUrl,
        updateUrl: updateUrl,
        removeUrl: removeUrl,
        exportUrl: exportUrl,
        sortName: "roleSort",
        modalName: "学院成绩分析",
        search: false,
        dataColumns: [
            {
                field: 'grade',
                title: '年级'
            },
            {
                field: 'courseName',
                title: '科目'
            },
            {
                field: 'college',
                title: '学院名称'
            },
            {
                field: 'avgRegularScore',
                title: '平时成绩'
            },
            {
                field: 'avgFinalScore',
                title: '期末成绩'
            },
            {
                field: 'stdFinalScore',
                title: '期末成绩标准差'
            },
            {
                field: 'avgTotalScore',
                title: '总评成绩'
            },
            {
                field: 'stdTotalScore',
                title: '总评成绩标准差'
            },
            {
                field: 'sumCollegeStu',
                title: '学院人数'
            },
            {
                field: 'sumExcellent',
                title: '优秀'
            },
            {
                field: 'sumGood',
                title: '良好'
            },
            {
                field: 'sumMedium',
                title: '中等'
            },
            {
                field: 'sunPass',
                title: '及格'
            },
            {
                field: 'sumFail',
                title: '不及格'
            },
            {
                title: '操作',
                formatter: function (value, row, index) {
                    var id = row.id;
                    var actions = [];
                    actions.push('<a class="btn btn-success btn-xs"  href="#" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>查看详情</a> ');
                    return actions.join('');
                }
            }]
    };
    $(function () {
        var oTab = $.table.oTableInit(options);
        oTab.Init();
    })


    $(function () {
        $("#college_select").select2({
            placeholder: "请选择"
        }).on("change", function (e) {
            majorList();
        })
        $("#grade-select").select2({
            placeholder: "请选择"
        });
        $("#course-select").select2({
            placeholder: "请选择"
        });
        $("#scoreOder").select2({
            placeholder: "请选择"
        });
    })
</script>

</body>


</html>
